﻿using System;
using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;

namespace JTLeigh.Commerce.Spencer.Features.ProductFeedback.Common.Entities
{

	/// <summary>
	/// Represents an attribute on which a product can be rated quantitatively.
	/// </summary>
	[SuppressMessage("Microsoft.Naming", "CA1711:IdentifiersShouldNotHaveIncorrectSuffix", Justification = "Reviewed.")]
	public class ProductRatingAttribute
	{

		#region Constructors

		/// <summary>
		/// Initiailizes a new instance of the <see cref="ProductRatingAttribute"/> class.
		/// </summary>
		public ProductRatingAttribute()
		{
			Localizations = new Dictionary<int, ProductRatingAttributeLocalization>();
		}

		#endregion // Constructors

		#region Properties

		/// <summary>
		/// Gets or sets the attribute identifier.
		/// </summary>
		/// <value>An attribute identifier <see cref="Guid"/>.</value>
		public Guid AttributeId { get; set; }

		/// <summary>
		/// Gets or sets the default attribute text.
		/// </summary>
		public string DefaultText { get; set; }

		/// <summary>
		/// Gets the list of the attribute's localizations.
		/// </summary>
		/// <value>A <see cref="Dictionary{TKey,TValue}"/> of <see cref="ProductReviewAttributeLocalization"/>
		/// keyed by culture identifier.</value>
		public Dictionary<int, ProductRatingAttributeLocalization> Localizations { get; private set; }

		#endregion // Properties

	}

}
